﻿using System.Windows;
using System.Windows.Controls.Primitives;
using nRoute.Behaviors;

namespace nRoute.Samples.Netflix.Behaviors
{
    public class PopupNavigationAdapterBehavior
        : NavigationAdapterBehaviorBase<Popup>
    {

#region Overides

        public override object Content
        {
            get { return this.AssociatedObject.Child; }
        }

        protected override void OnSetNavigationContent(object content)
        {
            this.AssociatedObject.Child = (UIElement)content;
            this.AssociatedObject.IsOpen = true;
        }

#endregion

    }
}
